function get_fc1_data() {
	$.ajax({
		url: "/fc1",
		success: function(data) {
			$(".num h1").eq(0).text(data.nowConfirm);
			$(".num h1").eq(1).text(data.nowConfirmAdd);
			$(".num h1").eq(2).text(data.heal);
			$(".num h1").eq(3).text(data.dead);
		},
		error: function(xhr, type, errorThrown) {

		}
	})
}
function get_fc2_data() {
    $.ajax({
        url:"/fc2",
        success: function(data) {
			ec_fcenter_option.series[0].data=data.data
            ec_fcenter.setOption(ec_fcenter_option)
		},
		error: function(xhr, type, errorThrown) {

		}
    })
}


function get_fc3_data() {
    $.ajax({
        url: "/fc3",
        success: function (data) {

            ec_fc3_option.xAxis.data=data.day
            ec_fc3_option.series[0].data=data.deadRate
            ec_fc3_option.series[1].data=data.healRate
            ec_fc3.setOption(ec_fc3_option)
        }
    })
}


function get_fl1_data() {
    $.ajax({
        url:"/fl1",
        success: function(data) {
			ec_fleft1_option.xAxis[0].data=data.day
            ec_fleft1_option.series[0].data=data.confirm
            ec_fleft1_option.series[1].data=data.heal
            ec_fleft1_option.series[2].data=data.dead
            ec_fleft1_option.series[3].data=data.newAddConfirm
            ec_fleft1.setOption(ec_fleft1_option)
		},
		error: function(xhr, type, errorThrown) {

		}
    })
}

function get_fl2_data() {
    $.ajax({
        url:"/fl2",
        success: function(data) {
            ec_fleft2_option.xAxis.data=data.city
            ec_fleft2_option.series[0].data=data.confirm
            ec_fleft2.setOption(ec_fleft2_option)
		},
		error: function(xhr, type, errorThrown) {

		}
    })
}
//
function get_fl3_data() {
    $.ajax({
        url: "/fl3",
        success: function (data) {

            ec_fleft3_option.yAxis.data=data.city;
            ec_fleft3_option.series[0].data=data.nowConfirm;
            ec_fleft3_option.series[1].data=data.dead;
            ec_fleft3.setOption(ec_fleft3_option);
        }
    })
}
function get_fr1_data() {
   $.ajax({
        url:"/fr1",
        success: function(data) {
           ec_fright1_option.series[0].data=data.data;
           ec_fright1.setOption(ec_fright1_option);
		},
		error: function(xhr, type, errorThrown) {

		}
    })
}

function get_fr2_data() {
    $.ajax({
        url: "/fr2",
        success: function (data) {
            ec_fright2_Option.series[0].data=data.data;
            ec_fright2.setOption(ec_fright2_Option);
        }
    })
}

function get_fr3_data() {
    $.ajax({
        url: "/fr3",
        success: function (data) {
            ec_fright3_option.series[0].data=data.kws;
            ec_fright3.setOption(ec_fright3_option);
        }
    })
}
get_fc1_data()
get_fc2_data()
get_fc3_data()
get_fl1_data()
get_fl2_data()
get_fl3_data()
get_fr1_data()
get_fr2_data()
get_fr3_data()


setInterval(get_fc1_data,1000*10)
setInterval(get_fc2_data,10000*10)
setInterval(get_fc3_data,1000*10)
setInterval(get_fl1_data,10000*10)
setInterval(get_fl2_data,10000*10)
setInterval(get_fl3_data,10000*10)
setInterval(get_fr1_data,10000*10)
setInterval(get_fr2_data,10000*10)
setInterval(get_fr3_data,10000*10)
